import $ from 'jquery';
import "bootstrap/dist/css/bootstrap.css"
import Vue from "vue";
import 'mint-ui/lib/style.css'
import vueRouter from "vue-router";
import router from "./router.js"
import moment from 'moment'
import mavonEditor from 'mavon-editor'
import 'mavon-editor/dist/css/index.css'
import VueQuillEditor from 'vue-quill-editor'
import 'quill/dist/quill.core.css'
import 'quill/dist/quill.snow.css'
import 'quill/dist/quill.bubble.css'
import Antd from 'ant-design-vue';
import 'ant-design-vue/dist/antd.css';
Vue.config.productionTip = false;
Vue.use(Antd);
import fastClick from 'fastclick'
fastClick.attach(document.body);
import VuePreview from'vue-preview'
Vue.use(VuePreview) 


Vue.config.productionTip = false;
Vue.use(VueQuillEditor)
Vue.use(mavonEditor)
Vue.prototype.$moment = moment
Vue.use(vueRouter)
import Vuex from 'vuex'
Vue.use(Vuex)
import MintUI from 'mint-ui'
import 'mint-ui/lib/style.css'
Vue.use(MintUI)
import App from "./App.vue"
import VueResource from 'vue-resource'
Vue.use(VueResource)
// 设置请求的根路径
Vue.http.options.root = 'http://localhost:3000';
// 全局设置 post 时候表单数据格式组织形式   application/x-www-form-urlencoded
Vue.http.options.emulateJSON = true;
import "./lib/css/style.css";
import "./lib/css/mui.min.css";
const store = new Vuex.Store({
    state: {
      newsfirstimg: "",
      comments_count:"",
    },
    mutations: {
      setnewlist_firstimg(state,imgurl){
        state.newsfirstimg = imgurl;
      },
      setcomments_count(state,count){
        state.comments_count = count;
      }
    },
    getters:{
        getnewlist_firstimg(state){
            return state.newsfirstimg;
        },
        getcommentscount(state){
          return state.comments_count;
        }
    }
  })
var vue = new Vue({
    el:"#app",
    render:c=>c(App),
    router,
    store
})